import request from '@/plugins/request';
export function CreateArticle(data) {
    return request({
        url: '/api/dfs/borrower/all',
        method: 'post',
        data
    });
}
export function getBorrowerById(data) {
    return request({
        url: '/api/dfs/borrower/getById',
        method: 'post',
        data
    });
}
export function getAllProcession(data) {
    return request({
        url: '/api/dfs/procession/allById',
        method: 'post',
        data
    });
}

export function deleteProcession(data) {
    return request({
        url: '/api/dfs/procession/deleteById',
        method: 'post',
        data
    });
}

export function changeDescription(data) {
    return request({
        url: '/api/dfs/procession/changeById',
        method: 'post',
        data
    });
}

export function addProcession(data) {
    return request({
        url: '/api/dfs/procession/add',
        method: 'post',
        data
    });
}


//获取景点列表
export function getAttractions() {
    return request({
        url: 'api/selectActivityCount',
        method: 'get'
    });
}

//根据景点id获取景点详情
export function getAttractionsById(id) {
    return request({
        url: `/api/selectAttractionsById/${id}`,
        method: 'get'
    });
}

//根据景点id获取景点图片
export function getPicturesById(id) {
    return request({
        url: `/api/selectPictureById/${id}`,
        method: 'get'
    });
}

//获取季节列表
export function getSeasons() {
    return request({
        url: '/api/selectSeasons',
        method: 'get'
    });
}

//获取推荐时间表
export function getRecommendTime() {
    return request({
        url: '/api/selectRecommendTime',
        method: 'get'
    });
}

//获取图片表
export function getPictures() {
    return request({
        url: '/api/getPictures',
        method: 'get'
    });
}

//删除季节
export function deleteSeason(season) {
    return request({
        url: `/api/delSeason?season=${season}`,
        method: 'delete'
    });
}

//添加季节
export function addSeason(data) {
    return request({
        url: '/api/addSeason',
        method: 'post',
        params: data
    });
}

//修改季节
export function updateSeason(data) {
    return request({
        url: '/api/updateSeason',
        method: 'post',
        params: data
    });
}

//根据季节查询
export function searchSeason(season) {
    return request({
        url: `/api/searchSeason?season=${season}`,
        method: 'get'
    });
}